package com.btsk.service;

import java.util.Date;
import java.util.List;
import java.util.Map;

import com.btsk.model.GpsInfo;
import com.btsk.model.NewGpsInfo;


public interface GpsInfoManager extends GenericManager<GpsInfo, Long> {

	GpsInfo findNewGpsInfoByCarIdAndStartTime(Long carId, String startTime);

	List<GpsInfo> findNewGpsInfoByCarIdsAndStartTime(String carIds,
			String startTime);

	List<GpsInfo> findNewGpsInfoStartTime(Date startTime);

	Long saveGpsInfo(GpsInfo gpsInfo);

	void saveGpsInfoAlarm(Long carId, Date warnTime, int type, int subType);


	int findGpsInfoCount(Map<String, Object> queryMap, Date startTime,
			Date endTime, int type, int subType, int valid, int minSpeed,
			int maxSpeed);


	List<GpsInfo> findGpsInfosByCarIdAndDay(Long carId, Date day);

	List<GpsInfo> findGpsInfosByCarIdAndDate(Long carId, Date startTime,
			Date endTime);

	List<GpsInfo> findNewGpsinfoInAreaId(Long areaId);


	// void saveGpsInfoAlarm(WarnMsgInform warnMsgInform,int type);

	Long computeGpsRegion(double lon, double lat);

	List<? extends GpsInfo> computGpsInfoText(List<? extends GpsInfo> gpsInfos);

	List<? extends GpsInfo> computGpsInfoText(List<? extends GpsInfo> gpsInfos,
			Integer detail);

	List<? extends GpsInfo> computGpsInfoEnLatlons(
			List<? extends GpsInfo> gpsInfos);

	GpsInfo computeOneGpsInfoText(GpsInfo gpsInfo);

	GpsInfo computeOneGpsInfoText(GpsInfo gpsInfo, Integer detail);

	GpsInfo computeOneGpsInfoLatlon(GpsInfo gpsInfo);

	

	List<NewGpsInfo> findNewGpsinfo();


}
